import type { FilterItem } from '@/components/FilterBar/types'
import { ref } from 'vue'

export const filterOptions = ref<Array<FilterItem>>([
  {
    label: '项目编号',
    prop: 'projectNo',
    type: 'input',
    defaultValue: '',
    span: 6,
    inputProps: {
      clearable: true,
      placeholder: '请输入项目编号'
    }
  },
  {
    label: '项目名称',
    prop: 'projectName',
    type: 'input',
    span: 6,
    inputProps: {
      clearable: true,
      placeholder: '请输入项目名称'
    }
  },
  {
    label: '项目单位',
    prop: 'projectCompany',
    type: 'input',
    span: 6,
    inputProps: {
      clearable: true,
      placeholder: '请输入项目单位'
    }
  },
  {
    label: '申请单号',
    prop: 'dailyConstructionNo',
    type: 'input',
    span: 6,
    inputProps: {
      clearable: true,
      placeholder: '请输入申请单号'
    }
  },
  {
    label: '上报时间',
    prop: 'date',
    type: 'datePicker',
    defaultValue: [],
    span: 8,
    inputProps: {
      type: 'datetimerange',
      format: 'YYYY-MM-DD HH:mm',
      'value-format': 'YYYY-MM-DD HH:mm',
      'start-placeholder': '开始时间',
      'end-placeholder': '结束时间',
      'range-separator':   '至'
    }
  },
  {
    label: '异常关键词',
    prop: 'errorDesc',
    type: 'input',
    span: 6,
    inputProps: {
      clearable: true,
      placeholder: '请输入异常关键词'
    }
  },
  {
    label: '航站楼',
    prop: 'terminalBuilding',
    type: 'radio',
    span: 10,
    defaultValue: undefined,
    inputProps: {
      showCheckAll: false,
      options: [
      ]
    },
  },
  {
    label: '项目类型', // 后续由接口获取下拉数据
    prop: 'projectType',
    type: 'radio',
    span: 24,
    defaultValue: '',
    inputProps: {
      showCheckAll: false,
      options: [
      ]
    },
    events: {
      change: (value: any, evt: any) => {
      }
    }
  },
])
